package stu.wingsmaker.wooohoo.view.activity;

import android.content.Intent;
import android.os.Bundle;
import android.os.Handler;
import android.view.Window;

import com.actionbarsherlock.app.SherlockActivity;
import com.example.woooohooooo.R;

public class IntroActivity extends SherlockActivity {
	Handler h;
	@Override
	protected void onCreate(Bundle savedInstanceState) {
		super.onCreate(savedInstanceState);
		requestWindowFeature(Window.FEATURE_NO_TITLE);
		setContentView(R.layout.activity_intro);
		
		h = new Handler();
		h.postDelayed(irun, 2000);
	}
	Runnable irun = new Runnable() {
		public void run() {
			Intent i = new Intent(IntroActivity.this, LoginActivity.class);
			startActivity(i);
			finish();
			
			overridePendingTransition(android.R.anim.fade_in, android.R.anim.fade_out);
		}
	};
	
	public void onBackPressed() {
		super.onBackPressed();
		h.removeCallbacks(irun);
	}
			
		



}
